package com.powernode.utils;

import com.powernode.constant.ResourceConstant;

import java.util.List;

/**
 * @Author LF
 * projectName:today-shop
 * description:
 * time:2022-09-18 21:18
 */
public class MyAllowPathUtil {
    public static String[] securityAllowPaths() {
        String[] resourceAllowUrls = ResourceConstant.RESOURCE_ALLOW_URLS;
        List<String> myRpcUrls = ResourceConstant.MY_RPC_URLS;
        String[] securityAllowPaths = new String[resourceAllowUrls.length + myRpcUrls.size()];
        for (int i = 0; i < resourceAllowUrls.length; i++) {
            securityAllowPaths[i] = resourceAllowUrls[i];
        }
        for (int i = 0; i < myRpcUrls.size(); i++) {
            securityAllowPaths[resourceAllowUrls.length + i] = myRpcUrls.get(i);
        }
        return securityAllowPaths;
    }
}
